-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
{crucible,crux}-llvm
: Adapt to elliottt/llvm-pretty#118
#1162
Conversation
@@ -133,8 +134,7 @@ makeGlobalMap ctx m = foldl' addAliases globalMap (Map.toList (llvmGlobalAliases | |||
++ ": " | |||
++ err) | |||
where showSymbol sym = | |||
show $ let ?config = LPP.Config False False False | |||
in LPP.ppSymbol $ sym | |||
show $ ppLLVMLatest $ LPP.ppSymbol $ sym |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I opted to change the Config
used here for consistency's sake. The ppSymbol
function doesn't make use of any Config
-specific options anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might be worth creating helpers such as ppType = ppLLVMLatest L.ppType
, etc.
This patch: * Bumps the `llvm-pretty` and `llvm-pretty-bc-parser` submodules to recent commits that include the changes from GaloisInc/llvm-pretty#118. * Introduces a `ppLLVMLatest` combinator to `Lang.Crucible.LLVM.PrettyPrint` that prints a `Fmt` value (from `Text.LLVM.PP`) using the latest version of LLVM that `llvm-pretty` supports. * Uses `ppLLVMLatest` in the appropriate places to fix compilation errors. Fixes #1145.
1038a36
to
4739fe7
Compare
(cherry picked from commit 6f940c1)
(cherry picked from commit d8fba04)
(cherry picked from commit d8fba04)
This patch:
llvm-pretty
andllvm-pretty-bc-parser
submodules to recent commits that include the changes from Use Fmt encapsulation and add LLVMPretty class llvm-pretty#118.ppLLVMLatest
combinator toLang.Crucible.LLVM.PrettyPrint
that prints aFmt
value (fromText.LLVM.PP
) using the latest version of LLVM thatllvm-pretty
supports.ppLLVMLatest
in the appropriate places to fix compilation errors.Fixes #1145.